﻿<%@ Page Title="" Language="C#" MasterPageFile="~/MasterPages/User.Master" AutoEventWireup="true" CodeBehind="GroupList.aspx.cs" Inherits="CRMWeb.Pages.Group.GroupList" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
    <script type="text/javascript">
        $(document).ready(function () {
            var flag = true;
            $('#tvGroupList').tree({
                url:'/WebServices/Group/Group.ashx?method=GetTreeGroupList',
                onSelect: function (node) {
                    
                    $('#hdnGroupID').val(node.id);
                    $('#hdnGroupNameForPriorityQueue').val(node.text);
                    if (flag == false)
                        $('#divGroupDetail').panel('refresh', '/Pages/Group/GroupDetail.aspx');
                    else
                        flag = false;
                },
                onLoadSuccess: function (node, data) {
                    var node = $('#tvGroupList').tree('find', 2);
                    $('#tvGroupList').tree('select', node.target);
                    $('#divGroupDetail').panel('refresh', '/Pages/Group/GroupDetail.aspx');
                    flag = false;
                }
            });
        });
    </script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <table style="width: 100%;">
        <tr>
            <td style="width: 25%; vertical-align: top;">
                    <ul id="tvGroupList"  data-options="animate:true"></ul>
            </td>
            <td style="vertical-align: top; width: 74%;">
                <input id="hdnGroupID" type="hidden" />
                <input id="hdnGroupNameForPriorityQueue" type="hidden" />
                <div id="divGroupDetail" class="easyui-panel" style="padding: 10px; width: auto; height: auto;">
                </div>
            </td>
        </tr>
    </table>
    <script type="text/javascript">
        fnLeftNavSelected('A1');
    </script>
</asp:Content>


